List Access Tokens
This API returns a list of access tokens available within the tenant.
Endpoint Details
| URL | /v1/auth/access-tokens |
| Method | GET |
| Authorization | Bearer Token |
Request Headers
| Header | Type | Description |
|---|---|---|
| Content-Type | String | Must be application/json |
Response
Here is an example of a response when viewing a list of data:
Response
{
"access_tokens": [
{
"id": "cc4a3b9a-bb48-49cf-8ee4-a07f88c3ff6d",
"tenant_id": "5ebde17c-01a1-4394-977b-9e611250cf5d",
"name": "Dummy",
"group_id": "81ad4d05-d11a-4809-b1f2-cc000c086730",
"allowed_ips": [
""
],
"expiration": true,
"expired_at": 1784246400,
"created_by": "0a937c60-0ed4-4d06-870a-2e284b54287d",
"updated_by": "0a937c60-0ed4-4d06-870a-2e284b54287d",
"created_at": 1784189995,
"updated_at": 1784189995,
"assigned_user_ids": [
"0a937c60-0ed4-4d06-870a-2e284b54287d"
]
},
{
"id": "f1a84190-e12c-43a2-b439-80461199e8c3",
"tenant_id": "5ebde17c-01a1-4394-977b-9e611250cf5d",
"name": "Tes Jeje",
"description": "coba tes",
"group_id": "81ad4d05-d11a-4809-b1f2-cc000c086730",
"allowed_ips": [
""
],
"created_by": "0a937c60-0ed4-4d06-870a-2e284b54287d",
"updated_by": "0a937c60-0ed4-4d06-870a-2e284b54287d",
"created_at": 1784183975,
"updated_at": 1784185151,
"assigned_user_ids": [
"0a937c60-0ed4-4d06-870a-2e284b54287d"
]
},
{
"id": "b80bf380-7beb-4c13-8cdc-d1de8829860a",
"tenant_id": "5ebde17c-01a1-4394-977b-9e611250cf5d",
"name": "Testes",
"group_id": "c10ac748-6218-4bd6-9ca0-97ea933da3d6",
"created_by": "0a11c692-b992-4d02-8a55-22b005459c50",
"updated_by": "0a11c692-b992-4d02-8a55-22b005459c50",
"created_at": 1784175521,
"updated_at": 1784175521,
"assigned_user_ids": [
"0a937c60-0ed4-4d06-870a-2e284b54287d"
]
},
{
"id": "809f74b3-ab30-4cd0-9bc9-5ab5a31f5699",
"tenant_id": "5ebde17c-01a1-4394-977b-9e611250cf5d",
"name": "Restricted",
"description": "47c9639c6c80fedc8e8b7904d6d2b18e01f259bd4a92003f34f8340624d4e201",
"group_id": "5ff4e1da-3d8d-4fde-9d01-52bde2b3bd3f",
"ip_restriction": true,
"allowed_ips": [
"kansdsadsa|192.168.40.192",
"fawwaz|192.168.40.199"
],
"created_by": "414a45e9-f194-4a8a-9876-97abb990d4d9",
"updated_by": "2ecec31b-ed78-4c8d-84b1-0d051e975951",
"created_at": 1781093215,
"updated_at": 1781516043,
"assigned_user_ids": [
"414a45e9-f194-4a8a-9876-97abb990d4d9"
]
},
{
"id": "fb3bccd4-1d35-469e-bd74-ef2289721d39",
"tenant_id": "5ebde17c-01a1-4394-977b-9e611250cf5d",
"name": "Expired 16 Jun",
"description": "b90ff7ee344c39e5efe45b15b23f4f89165aa9cf2a9d6dcec7319c4cf5b4d1cd",
"group_id": "5ff4e1da-3d8d-4fde-9d01-52bde2b3bd3f",
"expiration": true,
"expired_at": 1781568000,
"created_by": "414a45e9-f194-4a8a-9876-97abb990d4d9",
"updated_by": "414a45e9-f194-4a8a-9876-97abb990d4d9",
"created_at": 1781093173,
"updated_at": 1781494805,
"assigned_user_ids": [
"414a45e9-f194-4a8a-9876-97abb990d4d9"
]
},
{
"id": "79d4b106-22cc-44c1-a9c8-8d2ca542eff3",
"tenant_id": "5ebde17c-01a1-4394-977b-9e611250cf5d",
"name": "Token Member",
"description": "1e00d25a6b0cbdfc621df39372dc6d15497fd5cfb1328b83345f54b00951ac5b",
"group_id": "5ff4e1da-3d8d-4fde-9d01-52bde2b3bd3f",
"created_by": "f6fa5fe7-c4ea-413b-b74b-e8042b764c5d",
"updated_by": "f6fa5fe7-c4ea-413b-b74b-e8042b764c5d",
"created_at": 1780556683,
"updated_at": 1780556695,
"assigned_user_ids": [
"f6fa5fe7-c4ea-413b-b74b-e8042b764c5d"
]
},
{
"id": "c8b4ae62-fd3f-441d-9c4e-c2c1bc4078f6",
"tenant_id": "5ebde17c-01a1-4394-977b-9e611250cf5d",
"name": "Token Master",
"description": "0ecc2cd56e615bd0330ff597d8e794b31cec2680cca7183846200b1e12cd0b05",
"group_id": "5ff4e1da-3d8d-4fde-9d01-52bde2b3bd3f",
"created_by": "414a45e9-f194-4a8a-9876-97abb990d4d9",
"updated_by": "414a45e9-f194-4a8a-9876-97abb990d4d9",
"created_at": 1780022906,
"updated_at": 1780022916,
"assigned_user_ids": [
"c777977b-7a32-4040-b7b0-ee51721433fd"
]
},
{
"id": "5d458edf-a01f-4f7c-b267-995035ce924f",
"tenant_id": "5ebde17c-01a1-4394-977b-9e611250cf5d",
"name": "Akses Token",
"description": "b221e360671943e914984cc42c4a70e824e388f5f369cc48fa56f52c335e75a8",
"group_id": "5ff4e1da-3d8d-4fde-9d01-52bde2b3bd3f",
"created_by": "414a45e9-f194-4a8a-9876-97abb990d4d9",
"updated_by": "0a11c692-b992-4d02-8a55-22b005459c50",
"created_at": 1778763642,
"updated_at": 1782102944,
"assigned_user_ids": [
"7c6126c9-9bc3-4d05-9796-c3c1a7173de2"
]
},
],
"pagination": {
"total": 8,
"page": 1,
"page_size": 8,
"last_page": 1
}
}
Field Descriptions
| Field | Type | Description |
|---|---|---|
| id | UUID | Unique identifier of the access token |
| tenant_id | UUID | Identifier of the tenant that owns the access token |
| name | String | Name of the access token |
| description | String | Description of the access token |
| group_id | UUID | Identifier of the associated group |
| ip_restriction | Boolean | Indicates whether the access token is restricted to specific IPs |
| allowed_ips | Array | List of allowed IP addresses |
| expiration | Boolean | Indicates whether the access token has an expiration |
| expired_at | Integer | Expiration timestamp in Unix format |
| created_by | UUID | Identifier of the user who created the access token |
| updated_by | UUID | Identifier of the user who last updated the access token |
| created_at | Integer | Creation timestamp in Unix format |
| updated_at | Integer | Last update timestamp in Unix format |
| assigned_user_ids | Array | List of user IDs assigned to the access token |
| total | Integer | Total number of access tokens available |
| page | Integer | Current page number |
| page_size | Integer | Number of records returned per page |
| last_page | Integer | Total number of available pages |
info
- A valid Bearer Token is required to access this endpoint.
- The response returns all access tokens available within the tenant.
- Fields such as
description,ip_restriction,allowed_ips,expiration, andexpired_atmay not be present if those options were not configured when the access token was created. - The
api_keyis never returned by this endpoint, it is only shown once at creation or regeneration. - Unix timestamp fields can be converted to a human-readable date and time format as needed.